<div class="admin_left actions">
	<h3><?php echo __('Manage more'); ?></h3>
	<ul>
		<li style="list-style-type:none; margin-bottom:15%;"><?php echo $this->Html->link(__('Edit Color'), array('action' => 'edit', $color['Color']['id'])); ?> </li>
		<li style="list-style-type:none; margin-bottom:15%;"><?php echo $this->Form->postLink(__('Delete Color'), array('action' => 'delete', $color['Color']['id']), null, __('Are you sure you want to delete # %s?', $color['Color']['id'])); ?> </li>
		<li style="list-style-type:none; margin-bottom:15%;"><?php echo $this->Html->link(__('List Colors'), array('action' => 'index')); ?> </li>
		<li style="list-style-type:none; margin-bottom:15%;"><?php echo $this->Html->link(__('New Color'), array('action' => 'add')); ?> </li>
		<li style="list-style-type:none; margin-bottom:15%;"><?php echo $this->Html->link(__('List Items'), array('controller' => 'items', 'action' => 'index')); ?> </li>
		<li style="list-style-type:none; margin-bottom:15%;"><?php echo $this->Html->link(__('New Item'), array('controller' => 'items', 'action' => 'add')); ?> </li>
	</ul>
</div>

<div class="admin_right colors view">


<div id=breadcrumbAdmin>
    <?php $this->Html->addCrumb('Colours', '/Colors/index'); ?>
    <?php $this->Html->addCrumb('View', '/Colors/view', array('style'=> ('text-decoration:underline; color:#EB1E70;'))); ?>
    <?php echo $this->Html->getCrumbs(' > ', array( 'text' => 'Items', 'url' => array('controller' => 'items', 'action' => 'index'), 'escape' => false)); ?>
</div>

<h2><?php  echo __('Color'); ?></h2>
	<table class="table table-striped table-bordered">
            <tr>
                <th><?php echo __('Id'); ?></th>
                <th><?php echo __('Name'); ?></th>
            </tr>
            <tr>
                <td>
                            <?php echo h($color['Color']['id']); ?>
                            &nbsp;
                </td>

                <td>
                            <?php echo h($color['Color']['name']); ?>
                            &nbsp;
                </td>
            </tr>
	</table>

     <?php if ($current_customer['group_id'] == 1): ?> 

     <?php endif; ?>
    <div style="border-top:solid 1px; margin-top:10%;" class="related">
        <h4><?php echo __('Related Items'); ?></h4>
        <?php if (!empty($color['Item'])): ?>
            <table cellpadding = "0" cellspacing = "0" class="table table-striped table-bordered">
                <tr>
                    <th><?php echo __('Id'); ?></th>
                    <th><?php echo __('Name'); ?></th>
                    <th><?php echo __('Brand'); ?></th>
                    <th><?php echo __('Color'); ?></th>
                    <th><?php echo __('Condition'); ?></th>
                    <th><?php echo __('Size'); ?></th>
                    <th><?php echo __('Category'); ?></th>
                    <th><?php echo __('Item Status'); ?></th>
                    <th><?php echo __('Original Price'); ?></th>
                    <th class="actions"><?php echo __('Actions'); ?></th>
                </tr>
                <?php
                    $i = 0;
                    foreach ($color['Item'] as $item):
                ?>
                    <tr>
                        <td><?php echo $item['id']; ?></td>
                        <td><?php echo $item['name']; ?></td>
                        <td><?php echo $item['brand_id']; ?></td>
                        <td><?php echo $item['color_id']; ?></td>
                        <td><?php echo $item['condition_id']; ?></td>
                        <td><?php echo $item['size_id']; ?></td>
                        <td><?php echo $item['category_id']; ?></td>
                        <td><?php echo $item['item_status_id']; ?></td>
                        <td><?php echo $item['original_price']; ?></td>
                        <td class="actions">
                            <?php echo $this->Html->link(__('View'), array('controller' => 'items', 'action' => 'view', $item['id'])); ?>
                            <?php echo $this->Html->link(__('Edit'), array('controller' => 'items', 'action' => 'edit', $item['id'])); ?>
                            <?php echo $this->Form->postLink(__('Delete'), array('controller' => 'items', 'action' => 'delete', $item['id']), null, __('Are you sure you want to delete # %s?', $item['id'])); ?>
                        </td>
                    </tr>
                <?php endforeach; ?>
            </table>
        <?php endif; ?>

        <?php if ($current_customer['group_id'] == 1): ?>
            <div  style="margin-left:80%;" class="actions">
                <ul>
                    <li style="list-style-type:none; margin-left:0; padding-top:15px;"><?php echo $this->Html->link(__('Add Item to this color'), array('controller' => 'items', 'action' => 'add')); ?> </li>
                </ul>
            </div>
        <?php endif; ?>
    </div>
</div>
